<?php
/*
 * Copyright 2008 francissem (http://www.webmoss.net)(francissem@gmail.com)
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 * 		http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 *
 * @author francissem
 * @copyright 2008 francissem (http://www.webmoss.net)(francissem@gmail.com)
 * @license http://www.apache.org/licenses/LICENSE-2.0
 */
/**
 * 
 * Core_Exception use for all core package exception, record down all exceptions log here
 * 
 */
class Core_Exception extends Exception{
	const PHP_ERROR=1;
	function __construct($message="",$code=0){
		parent::__construct($message,$code);
		
		
		
		/*$structure_setting = Core_System::GetSetting("structure");

		$conn = array("path"=>pathjoin(__ROOT__,$structure_setting["log_location"]));
		require_once(__LIBRARY__."/Core/Repository.php");
		$log = new System_Logger(Core_Repository::factory("file",$conn));

		$log->writeException($this);
		$general_setting = Core_System::GetSetting("general");
		if($general_setting["mode"]=="debug"){
			header("Content-Type: text/plain");
			header("System-Message-Type: error");
			echo $log->createContentByException($this);
		}*/
	}
}
?>